From: Wei Liu Date: Fri, 16 Nov 2018 18:58:55 +0000 (+0000) Subject: x86: fix efi.lds dependency generation X-Git-Tag: archive/raspbian/4.14.0+80-gd101b417b7-1+rpi1^2~63^2~2907 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=30311d2e82a3eb69aa1667382a6b2529f6d944c4;p=xen.git x86: fix efi.lds dependency generation RANDCONFIG builds discover efi.lds is not updated when autogenerated headers are updated. Upon inspection, the generated .d file contains xen.lds.o as target, not the once thought efi.lds.o. That's because gcc disregards the output object name specified by -o when generating dependency, so the sed invocation has no effect. Arguably that's a bug in gcc, which can be fixed at some point, so we make the sed rune work with *.lds. At the same time replace the hardcoded sed rune for xen.lds with the new one. Signed-off-by: Wei Liu Acked-by: Jan Beulich --- diff --git a/xen/arch/x86/Makefile b/xen/arch/x86/Makefile index 162b0b94c0..484dcb7ce7 100644 --- a/xen/arch/x86/Makefile +++ b/xen/arch/x86/Makefile @@ -234,12 +234,12 @@ $(BASEDIR)/include/asm-x86/asm-macros.h: asm-macros.i Makefile xen.lds: xen.lds.S $(CC) -P -E -Ui386 $(filter-out -Wa$(comma)%,$(AFLAGS)) -o $@ $< - sed -e 's/xen\.lds\.o:/xen\.lds:/g' <.xen.lds.d >.xen.lds.d.new - mv -f .xen.lds.d.new .xen.lds.d + sed -e 's/.*\.lds\.o:/$(@F):/g' <.$(@F).d >.$(@F).d.new + mv -f .$(@F).d.new .$(@F).d efi.lds: xen.lds.S $(CC) -P -E -Ui386 -DEFI $(filter-out -Wa$(comma)%,$(AFLAGS)) -o $@ $< - sed -e 's/efi\.lds\.o:/efi\.lds:/g' <.$(@F).d >.$(@F).d.new + sed -e 's/.*\.lds\.o:/$(@F):/g' <.$(@F).d >.$(@F).d.new mv -f .$(@F).d.new .$(@F).d boot/mkelf32: boot/mkelf32.c